<?php

/**
 * Created by PhpStorm.
 * User: Simpson
 * Date: 2016/8/31
 * Time: 1:25
 */
namespace App\Http\Controllers\Operation;


use App\Http\Controllers\Controller;
use App\Model\Feedback;
use OperationService;
use App\Model\User;
use Illuminate\Http\Request;
class FeedbackController extends Controller
{
    public function repairFeedback(Request $request)
    {
        $this->validate($request, [
            'content' => 'required'
        ]);

        //添加维护反馈信息
        $result = OperationService::createFeedback($request);
        
        return $result? response()->json(['msg' => 'ok', 'target' => route('repair')]): response()->json(['msg' => '反馈失败']);
    }
}